tools: build fixes for NetBSD
authorKeir Fraser <keir.fraser@citrix.com>
Tue, 12 Jan 2010 06:55:24 +0000 (06:55 +0000)
committerKeir Fraser <keir.fraser@citrix.com>
Tue, 12 Jan 2010 06:55:24 +0000 (06:55 +0000)
Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
tools/libxl/libxl.h
tools/libxl/xl.c
tools/xenpaging/file_ops.c

index 9fc74c5973f0fc28dc08d1871c5109884794fa5a..529dbd6de2ac24d0bc00889f2822c21d19b06b2e 100644 (file)
@@ -20,6 +20,7 @@
 #include <netinet/in.h>
 #include <xenctrl.h>
 #include <xs.h>
+#include <sys/wait.h> /* for pid_t */
 
 typedef void (*libxl_log_callback)(void *userdata, int loglevel, const char *file,
                                    int line, const char *func, char *s);
index 996965bc22b0664d1f6578d00542d1d6f3d194a5..3be7acf0a492f1b1a6e3ecdee03ab983df6794c1 100644 (file)
@@ -53,7 +53,7 @@ static int domain_qualifier_to_domid(struct libxl_ctx *ctx, char *p, uint32_t *d
 
     alldigit = 1;
     for (i = 0; p[i]; i++) {
-        if (!isdigit(p[i])) {
+        if (!isdigit((uint8_t)p[i])) {
             alldigit = 0;
             break;
         }
index 0b90459de16aa5595ddd656e7d2fffa5f010b730..2d52827669d9a538bc65ae76bfe0a962aa628041 100644 (file)
@@ -36,7 +36,7 @@ static int file_op(int fd, void *page, int i,
     int bytes;
     int ret;
 
-    seek_ret = lseek64(fd, i << PAGE_SHIFT, SEEK_SET);
+    seek_ret = lseek(fd, i << PAGE_SHIFT, SEEK_SET);
 
     total = 0;
     while ( total < PAGE_SIZE )